package com.yizhilu.os.com.yizhilu.os.edu.dao.impl.kuaijidao;

import com.yizhilu.os.com.yizhilu.os.edu.dao.kuaijidao.UserKuaijidaoDao;
import com.yizhilu.os.core.dao.impl.common.GenericDaoImpl;
import com.yizhilu.os.edu.entity.kuaijidao.WeixinBind;
import com.yizhilu.os.edu.entity.kuaijidao.WeixinSendMsg;
import com.yizhilu.os.edu.entity.kuaijidao.WxTemplate;
import com.yizhilu.os.edu.entity.kuaijidao.WeixinTempMsgLog;

import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;


/**
 * Created by Administrator on 2016/6/22.
 */
@Repository("userKuaijidaoDao")
public class UserKuaijidaoDaoImpl extends GenericDaoImpl implements UserKuaijidaoDao{

    public List getUserByOpenId(String openId){
        return this.selectList("KuaijidaoMapper.getUserByOpenId",openId);
    }

    public long addBindWeixin(WeixinBind weixinBind){
        return this.insert("KuaijidaoMapper.addBind", weixinBind);
    }
    
    public long addWeiTempMsg(WeixinSendMsg weixinSendMsg){
        return this.insert("KuaijidaoMapper.addWeixinTempMsg", weixinSendMsg);
    }
    
    public long updateWeiTempMsg(int id){
        return this.insert("KuaijidaoMapper.updateWeixinTempMsgById", id);
    }
    
    public List getWeiTempMsgByStatus(int isSend){
        return this.selectList("KuaijidaoMapper.getWeiTempMsgByStatus",isSend);
    }
    
    public List getCourseKpoint(String id){
        return this.selectList("KuaijidaoMapper.getCourseKpoint",id);
    }
    
    public List getTempMsgOpenId(){
        return this.selectList("KuaijidaoMapper.getTempMsgOpenId",null); 
    }
    
    public long addWeiTempMsgLog(WeixinTempMsgLog weixinTempMsgLog){
        return this.insert("KuaijidaoMapper.addWeixinTempMsgLog", weixinTempMsgLog);
    }
    
  

}
